package com.yun.blog.bean.dto;

import com.baomidou.mybatisplus.annotation.TableField;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.yun.blog.bean.User;
import lombok.Data;

import java.io.Serializable;
import java.util.Date;
import java.util.List;

/**
 * @author : simple
 * @title : BlogDto
 * @projectName : dantouBlog-back
 * @description : TODO
 * @email : yun_simple@163.com
 * @date : 2023/5/13下午11:43
 */

@Data
public class BlogDto implements Serializable {


    private Integer blogId;
    private Integer authorId;
    private User author;
    private String blogTitle;
    private String blogImg;
    private String blogContent;
    private String blogAbstract;
    private Integer blogCategoryId;

    // 标签列表
    @TableField(exist = false)
    private List<Integer> tagIds;

    // 博客状态，ture发布，false草稿
    private Boolean blogStatus;
    // 浏览量
    private Integer blogViews;
    // 是否允许评论
    private Boolean enableComment;
    private Boolean isDeleted;
    private Boolean isTop;

    @JsonFormat(pattern = "yyyy年MM月dd日 hh:mm:ss", timezone = "GMT+8")
    private Date createTime;
    @JsonFormat(pattern = "yyyy年MM月dd日 hh:mm:ss", timezone = "GMT+8")
    private Date updateTime;

    @JsonFormat(pattern = "yyyy年MM月dd日 hh:mm:ss", timezone = "GMT+8")
    private Date releaseTime;

}
